<%@ page contentType="text/html;charset=UTF-8"%>
<%@ include file="/common/taglibs.jsp"%>
<%@ page import="org.acegisecurity.ui.webapp.AuthenticationProcessingFilter"%>
<html>
	<head>
		<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
		<meta http-equiv="Cache-Control" content="no-store"/>
		<meta http-equiv="Pragma" content="no-cache"/>
		<meta http-equiv="Expires" content="0"/>
		<title>登陆</title>
	<style type="text/css">
	* {font-size:12px;}
	.label {width:60px;height:30px;text-align:right;}
	.input {width:126px;}
	.input input {width:100px;}
	</style>
	</head>
	<body>
		<div style="height:110px;width:100%;"></div>
		<div>
         	<div style="text-align:center">
			<c:if test="${not empty param.login_error}">
				<font color="red"> 登录失败<BR /> 原因: 用户不存在或密码错误 </font>
			</c:if>
			<c:if test="${param.error == 2}">
				<font color="red"> 验证码错误 </font>
			</c:if>
         	</div>
			<form action="<c:url value='j_acegi_security_check'/>" method="POST">
				<table style="height:270px;width:100%;">
					<tr>
						<td style="width:216px;">
							&nbsp;
						</td>
						<td style="width:186px;vertical-align:middle;">
							<table>
								<tr>
									<td class="label">
										帐号:
									</td>
									<td class="input">
										<input type='text' name='j_username' <c:if test="${param.login_error == 1}">value='<%=session.getAttribute(AuthenticationProcessingFilter.ACEGI_SECURITY_LAST_USERNAME_KEY)%>'</c:if> />
									</td>
								</tr>
								<tr>
									<td class="label">
										密码:
									</td>
									<td class="input">
										<input type='password' name='j_password' />
									</td>
								</tr>
								<tr>
									<td colspan="2" style="text-align:right;padding:0 40px;">
										<img id="captchaImg" src="<c:url value='/jcaptcha.jpg'/>" />
									</td>
								</tr>
								<tr>
									<td class="label">
										验证码:
									</td>
									<td class="input">
										<input type='text' name='j_captcha' value="RPWT54321" />
									</td>
								</tr>
								<tr>
									<td colspan='2'>
										&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
										<input name="submit" type="submit" value="登陆" />
									</td>
								</tr>
							</table>
						</td>
						<td style="background-color:#ccc">
							<span>&nbsp;</span>
						</td>
					</tr>
				</table>
			</form>
		</div>
	</body>
</html>
